package moni.anyou.com.view.view;

import android.os.Bundle;

import androidx.recyclerview.widget.GridLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.TextView;
import android.widget.Toast;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;

import moni.anyou.com.view.R;
import moni.anyou.com.view.base.BaseFragment;
import moni.anyou.com.view.bean.InitTripDataBean;
import moni.anyou.com.view.bean.request.ReqHomeBean;
import moni.anyou.com.view.config.SysConfig;
import moni.anyou.com.view.utils.KJHttpBuild;
import moni.anyou.com.view.view.fragmentadapter.DayAdapter;

public class DailyFragment extends BaseFragment {
    private RecyclerView recyclerView;
    private View mView;
    DayAdapter adapter;
    private int[] icons = {R.drawable.laba, R.drawable.shipu, R.drawable.kecheng, R.drawable.zuopin_33, R.drawable.shijian, R.drawable.liuyan, R.drawable.xinxiang, R.drawable.shengri_39};

    private String[] title = {"通知作业", "宝宝食谱", "课程表", "幼儿作品", "宝宝考勤", "班级留言栏", "园长信箱", "生日榜",};


    public DailyFragment() {

    }

    @Override
    public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
        mView = inflater.inflate(R.layout.fragment_day, container, false);

        init(mView);


        return mView;
    }

    @Override
    public void initView() {
        super.initView();
        tvTitle = (TextView) mView.findViewById(R.id.page_title);
        tvTitle.setText("日常");
        recyclerView = (RecyclerView) mView.findViewById(R.id.recy_day);
        recyclerView.setLayoutManager(new GridLayoutManager(getActivity(), 3));
        adapter = new DayAdapter(icons, title);
        recyclerView.setAdapter(adapter);


    }


    @Override
    public void onResume() {
        super.onResume();

    }



}
